﻿using System;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Ink;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Shapes;

namespace SilverAmp
{
	public partial class MainPage : UserControl
	{
		public MainPage()
		{
			// Required to initialize variables
			InitializeComponent();
		}

		private void TitleBar_MouseLeftButtonDown(object sender, System.Windows.Input.MouseButtonEventArgs e)
		{
            
			if (Application.Current.IsRunningOutOfBrowser)
		    {
        		Application.Current.MainWindow.DragMove();
    		}
		}

		private void CloseButton_Click(object sender, System.Windows.RoutedEventArgs e)
		{
			if (Application.Current.IsRunningOutOfBrowser)
		    {
        		Application.Current.MainWindow.Close();
    		}
		
		}

		private void MinimizeButton_Click(object sender, System.Windows.RoutedEventArgs e)
		{
			if (Application.Current.IsRunningOutOfBrowser)
		    {
		        Application.Current.MainWindow.WindowState = WindowState.Minimized;
    		}
		
		}
	}
}